﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

class Runway : Surface {
    private String direction1;
    private String direction2;
    private Node labelLocation;
    private Boolean arrivals;
    private Boolean departures;

    public Runway()
        : base() {

    }

    public String Direction1 {
        set { this.direction1 = value; }
    }

    public String Direction2 {
        set { this.direction2 = value; }
    }

    public Boolean Arrivals {
        set { this.arrivals = value; }
    }

    public Boolean Departures {
        set { this.departures = value; }
    }

    public void SetLabelLocation(String nodeString, double scaleX = 1, double scaleY = 1) {
        this.labelLocation = this.parseNodeFromString(nodeString, scaleX, scaleY);
    }

    public override String ToString() {
        String output = "{ Runway \n" +
                        "\t Direction1: " + this.direction1 + ", Direction2: " + this.direction2 + "\n" +
                        "\t LabelLocation: " + this.labelLocation + "\n" +
                        "\t MaxWeight: " + this.maxWeight + "\n" +
                        "\t Width: " + this.width + "\n" +
                        "\t Arrivals: " + this.arrivals + ", Departures: " + this.departures + "\n" +
                        "\t Nodes: \n";

        foreach(Node node in this.nodes) {
            output += "\t\t [" + node + "]\n";
        }

        output += "}";

        return output;
    }
}
